package org.yocastlong.mybatisplus.db.domain;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;
import org.yocastlong.mybatisplus.db.handle.FiledSm4EncryptHandle;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 *
 * </p>
 *
 * @author castlong
 * @since 2025-06-06
 */
@Data
@TableName(value = "t_user", autoResultMap = true)
public class UserDO implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private String id;

    /**
     * 账号
     */
    private String account;

    /**
     * 密码
     */
    @TableField(typeHandler = FiledSm4EncryptHandle.class)
    private String password;

    /**
     * 手机号
     */
    @TableField(typeHandler = FiledSm4EncryptHandle.class)
    private String phone;


    @TableField(typeHandler = FiledSm4EncryptHandle.class)
    private String username;


    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;

    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;


}
